← Back to issue list

snapcraft --use-lxd should have message about requring sudo

View original Launchpad issue

Metadata

Project
snapcraft (launchpad)
Number
#1865230
Type
issue
State
open
Author
~haydenb
Labels
Created
2020-02-28 23:46:34.967345+00:00
Updated
2020-03-13 12:33:20.501972+00:00
Closed

Current evaluation

No evaluation has been recorded for this issue yet.

Issue body

Running $ snapcraft --use-lxd will set up LXD but it will not connect: hayden@ubuntu:~/ghost-desktop$ snapcraft --use-lxd Support for 'LXD' needs to be set up. Would you like to do that it now? [y/N]: y snapd is not logged in, snap install commands will use sudo lxd 3.21 from Canonical✓ installed Error: LXD still not running after 30s timeout (Get http://unix.socket/1.0: dial unix /var/snap/lxd/common/lxd/unix.socket: connect: permission denied) Timeout reached waiting for LXD to start. Then, naturally, you try $ sudo snapcraft --use-lxd but get this: hayden@ubuntu:~/ghost-desktop$ sudo snapcraft --use-lxd The LXD provider is offered as a technology preview for early adopters. The command line interface, container names or lifecycle handling may change in upcoming releases. Launching a container. An error occurred with the instance when trying to launch with 'LXD': No storage pool found. Please create a new storage pool. Ensure that 'LXD' is setup correctly and try again. The fix is to $ snap remove lxd --purge and then $ sudo snapcraft --use-lxd. Because using snapcraft --use-lxd without sudo leaves it in an unusable state, perhaps it should fail and exit if --use-lxd is enabled without sudo.

Evaluation history

No evaluation history available.